Another fix in gpx.cc. With this, vtesto runs to completion on Ubuntu 12.04.
authorrobertlipe@gmail.com <robertlipe@gmail.com@f51c46e8-681c-474f-0cfe-069cfd0219fb>
Sun, 25 Aug 2013 21:25:07 +0000 (21:25 +0000)
committerrobertlipe@gmail.com <robertlipe@gmail.com@f51c46e8-681c-474f-0cfe-069cfd0219fb>
Sun, 25 Aug 2013 21:25:07 +0000 (21:25 +0000)
git-svn-id: http://gpsbabel.googlecode.com/svn/trunk@4573 f51c46e8-681c-474f-0cfe-069cfd0219fb

gpsbabel/gpx.cc

index 852504dddfd4e455fa3ecfdaf2090f8a82f58ed8..27cdcc123228d9ab60f4c0328e0a29edffd01151 100644 (file)
@@ -206,18 +206,17 @@ gpx_add_to_global(gpx_global_entry* ge, const QString& s)
 {
   queue* elem, *tmp;
   gpx_global_entry* gep;
-  const char* cdata = CSTR(s);
 
   QUEUE_FOR_EACH(&ge->queue, elem, tmp) {
     gep = BASE_STRUCT(elem, gpx_global_entry, queue);
-    if (0 == strcmp(cdata, gep->tagdata)) {
+    if (0 == s.compare(gep->tagdata)) {
       return;
     }
   }
 
   gep = (gpx_global_entry*) xcalloc(sizeof(*gep), 1);
   QUEUE_INIT(&gep->queue);
-  gep->tagdata = xstrdup(cdata);
+  gep->tagdata = xstrdup(CSTR(s));
   ENQUEUE_TAIL(&ge->queue, &gep->queue);
 }